<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <link rel="stylesheet" href="../css/jpetstore.css" type="text/css">
</head>
<body>
<div th:replace="common/top2"/>
<div id="Content">
    <h2>Account</h2>
    <table>
        <tr>
            <th>User Id</th>
            <th>Password</th>
<!--            <th>Email</th>-->
<!--            <th>FirstName</th>-->
<!--            <th>LastName</th>-->
<!--            <th>Status</th>-->
<!--            <th>Address1</th>-->
<!--            <th>Address2</th>-->
<!--            <th>City</th>-->
<!--            <th>State</th>-->
<!--            <th>Zip</th>-->
<!--            <th>Country</th>-->
<!--            <th>Phone</th>-->
            <th>Update</th>
            <th>Delete</th>
        </tr>
        <!-- 循环 -->

        <tr th:each="account:${accountList}">
            <form action="/account/update" method="post">
            <td><a th:href="@{'/account/viewAccount'(username=${account.username})}" th:text="${account.username}" style="margin: 0 auto;"></a></td>
            <td><input type="text" name="password" th:value="${account.password}" th:onclick="" style="margin: 0 auto;"/><input type="hidden" name="username" th:value="${account.username}"></td>
<!--            <td><input type="text" name="email" th:value="${account.email}" th:onclick="" style="margin: 0 auto; width:50px"/></td>-->
<!--            <td><input type="text" name="firstName" th:value="${account.firstName}" th:onclick="" style="margin: 0 auto; width:50px"/></td>-->
<!--            <td><input type="text" name="lastName" th:value="${account.lastName}" th:onclick="" style="margin: 0 auto; width:50px"/></td>-->
<!--            <td><input type="text" name="status" th:value="${account.status}" th:onclick="" style="margin: 0 auto; width:50px"/></td>-->
<!--            <td><input type="text" name="address1" th:value="${account.address1}" th:onclick="" style="margin: 0 auto; width:50px"/></td>-->
<!--            <td><input type="text" name="address2" th:value="${account.address2}" th:onclick="" style="margin: 0 auto; width:50px"/></td>-->
<!--            <td><input type="text" name="city" th:value="${account.city}" th:onclick="" style="margin: 0 auto; width:50px"/></td>-->
<!--            <td><input type="text" name="state" th:value="${account.state}" th:onclick="" style="margin: 0 auto; width:50px"/></td>-->
<!--            <td><input type="text" name="zip" th:value="${account.zip}" th:onclick="" style="margin: 0 auto; width:50px"/></td>-->
<!--            <td><input type="text" name="country" th:value="${account.country}" th:onclick="" style="margin: 0 auto; width:50px"/></td>-->
<!--            <td><input type="text" name="phone" th:value="${account.phone}" th:onclick="" style="margin: 0 auto; width:50px"/></td>-->
            <td><input type="submit" value="Update" style="margin: 0 auto; background-color: transparent"/></td>
            <td><a th:href="@{'/account/delete'(username=${account.username})}" th:text="Delete" style="margin: 0 auto; width:50px">Delete</a></td>
            </form>
        </tr>

    </table>

</div>

<div th:replace="common/bottom"/>
</body>
</html>